Optimal. Leaf size=78 \[ -2 a b m n x+2 b^2 m^2 n^2 x-\frac {2 b^2 m n (e+f x) \log \left (c \left (d (e+f x)^m\right )^n\right )}{f}+\frac {(e+f x) \left (a+b \log \left (c \left (d (e+f x)^m\right )^n\right )\right )^2}{f} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.07, antiderivative size = 78, normalized size of antiderivative = 1.00, number of steps
used = 5, number of rules used = 4, integrand size = 20, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.200, Rules used = {2436, 2333,
2332, 2495} \begin {gather*} \frac {(e+f x) \left (a+b \log \left (c \left (d (e+f x)^m\right )^n\right )\right )^2}{f}-2 a b m n x-\frac {2 b^2 m n (e+f x) \log \left (c \left (d (e+f x)^m\right )^n\right )}{f}+2 b^2 m^2 n^2 x \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2332
Rule 2333
Rule 2436
Rule 2495
Rubi steps
\begin {align*} \int \left (a+b \log \left (c \left (d (e+f x)^m\right )^n\right )\right )^2 \, dx &=\text {Subst}\left (\int \left (a+b \log \left (c d^n (e+f x)^{m n}\right )\right )^2 \, dx,c d^n (e+f x)^{m n},c \left (d (e+f x)^m\right )^n\right )\\ &=\text {Subst}\left (\frac {\text {Subst}\left (\int \left (a+b \log \left (c d^n x^{m n}\right )\right )^2 \, dx,x,e+f x\right )}{f},c d^n (e+f x)^{m n},c \left (d (e+f x)^m\right )^n\right )\\ &=\frac {(e+f x) \left (a+b \log \left (c \left (d (e+f x)^m\right )^n\right )\right )^2}{f}-\text {Subst}\left (\frac {(2 b m n) \text {Subst}\left (\int \left (a+b \log \left (c d^n x^{m n}\right )\right ) \, dx,x,e+f x\right )}{f},c d^n (e+f x)^{m n},c \left (d (e+f x)^m\right )^n\right )\\ &=-2 a b m n x+\frac {(e+f x) \left (a+b \log \left (c \left (d (e+f x)^m\right )^n\right )\right )^2}{f}-\text {Subst}\left (\frac {\left (2 b^2 m n\right ) \text {Subst}\left (\int \log \left (c d^n x^{m n}\right ) \, dx,x,e+f x\right )}{f},c d^n (e+f x)^{m n},c \left (d (e+f x)^m\right )^n\right )\\ &=-2 a b m n x+2 b^2 m^2 n^2 x-\frac {2 b^2 m n (e+f x) \log \left (c \left (d (e+f x)^m\right )^n\right )}{f}+\frac {(e+f x) \left (a+b \log \left (c \left (d (e+f x)^m\right )^n\right )\right )^2}{f}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.01, size = 69, normalized size = 0.88 \begin {gather*} \frac {(e+f x) \left (a+b \log \left (c \left (d (e+f x)^m\right )^n\right )\right )^2}{f}-2 b m n \left (a x-b m n x+\frac {b (e+f x) \log \left (c \left (d (e+f x)^m\right )^n\right )}{f}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [F]
time = 0.03, size = 0, normalized size = 0.00 \[\int \left (a +b \ln \left (c \left (d \left (f x +e \right )^{m}\right )^{n}\right )\right )^{2}\, dx\]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.30, size = 159, normalized size = 2.04 \begin {gather*} -2 \, a b f m n {\left (\frac {x}{f} - \frac {e \log \left (f x + e\right )}{f^{2}}\right )} + b^{2} x \log \left (\left ({\left (f x + e\right )}^{m} d\right )^{n} c\right )^{2} + 2 \, a b x \log \left (\left ({\left (f x + e\right )}^{m} d\right )^{n} c\right ) - {\left (2 \, f m n {\left (\frac {x}{f} - \frac {e \log \left (f x + e\right )}{f^{2}}\right )} \log \left (\left ({\left (f x + e\right )}^{m} d\right )^{n} c\right ) + \frac {{\left (e \log \left (f x + e\right )^{2} - 2 \, f x + 2 \, e \log \left (f x + e\right )\right )} m^{2} n^{2}}{f}\right )} b^{2} + a^{2} x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 238 vs.
\(2 (82) = 164\).
time = 0.36, size = 238, normalized size = 3.05 \begin {gather*} \frac {b^{2} f n^{2} x \log \left (d\right )^{2} + b^{2} f x \log \left (c\right )^{2} + {\left (b^{2} f m^{2} n^{2} x + b^{2} m^{2} n^{2} e\right )} \log \left (f x + e\right )^{2} - 2 \, {\left (b^{2} f m n - a b f\right )} x \log \left (c\right ) + {\left (2 \, b^{2} f m^{2} n^{2} - 2 \, a b f m n + a^{2} f\right )} x - 2 \, {\left ({\left (b^{2} f m^{2} n^{2} - a b f m n\right )} x + {\left (b^{2} m^{2} n^{2} - a b m n\right )} e - {\left (b^{2} f m n x + b^{2} m n e\right )} \log \left (c\right ) - {\left (b^{2} f m n^{2} x + b^{2} m n^{2} e\right )} \log \left (d\right )\right )} \log \left (f x + e\right ) + 2 \, {\left (b^{2} f n x \log \left (c\right ) - {\left (b^{2} f m n^{2} - a b f n\right )} x\right )} \log \left (d\right )}{f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 178 vs.
\(2 (76) = 152\).
time = 0.64, size = 178, normalized size = 2.28 \begin {gather*} \begin {cases} a^{2} x + \frac {2 a b e \log {\left (c \left (d \left (e + f x\right )^{m}\right )^{n} \right )}}{f} - 2 a b m n x + 2 a b x \log {\left (c \left (d \left (e + f x\right )^{m}\right )^{n} \right )} - \frac {2 b^{2} e m n \log {\left (c \left (d \left (e + f x\right )^{m}\right )^{n} \right )}}{f} + \frac {b^{2} e \log {\left (c \left (d \left (e + f x\right )^{m}\right )^{n} \right )}^{2}}{f} + 2 b^{2} m^{2} n^{2} x - 2 b^{2} m n x \log {\left (c \left (d \left (e + f x\right )^{m}\right )^{n} \right )} + b^{2} x \log {\left (c \left (d \left (e + f x\right )^{m}\right )^{n} \right )}^{2} & \text {for}\: f \neq 0 \\x \left (a + b \log {\left (c \left (d e^{m}\right )^{n} \right )}\right )^{2} & \text {otherwise} \end {cases} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 303 vs.
\(2 (82) = 164\).
time = 6.76, size = 303, normalized size = 3.88 \begin {gather*} \frac {{\left (f x + e\right )} b^{2} m^{2} n^{2} \log \left (f x + e\right )^{2}}{f} - \frac {2 \, {\left (f x + e\right )} b^{2} m^{2} n^{2} \log \left (f x + e\right )}{f} + \frac {2 \, {\left (f x + e\right )} b^{2} m n^{2} \log \left (f x + e\right ) \log \left (d\right )}{f} + \frac {2 \, {\left (f x + e\right )} b^{2} m^{2} n^{2}}{f} + \frac {2 \, {\left (f x + e\right )} b^{2} m n \log \left (f x + e\right ) \log \left (c\right )}{f} - \frac {2 \, {\left (f x + e\right )} b^{2} m n^{2} \log \left (d\right )}{f} + \frac {{\left (f x + e\right )} b^{2} n^{2} \log \left (d\right )^{2}}{f} + \frac {2 \, {\left (f x + e\right )} a b m n \log \left (f x + e\right )}{f} - \frac {2 \, {\left (f x + e\right )} b^{2} m n \log \left (c\right )}{f} + \frac {2 \, {\left (f x + e\right )} b^{2} n \log \left (c\right ) \log \left (d\right )}{f} - \frac {2 \, {\left (f x + e\right )} a b m n}{f} + \frac {{\left (f x + e\right )} b^{2} \log \left (c\right )^{2}}{f} + \frac {2 \, {\left (f x + e\right )} a b n \log \left (d\right )}{f} + \frac {2 \, {\left (f x + e\right )} a b \log \left (c\right )}{f} + \frac {{\left (f x + e\right )} a^{2}}{f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.28, size = 111, normalized size = 1.42 \begin {gather*} {\ln \left (c\,{\left (d\,{\left (e+f\,x\right )}^m\right )}^n\right )}^2\,\left (b^2\,x+\frac {b^2\,e}{f}\right )+x\,\left (a^2-2\,a\,b\,m\,n+2\,b^2\,m^2\,n^2\right )-\frac {\ln \left (e+f\,x\right )\,\left (2\,b^2\,e\,m^2\,n^2-2\,a\,b\,e\,m\,n\right )}{f}+2\,b\,x\,\ln \left (c\,{\left (d\,{\left (e+f\,x\right )}^m\right )}^n\right )\,\left (a-b\,m\,n\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________